Imports pixolut.BizBlox

Public Class StudentCollection
    Inherits DOCollection

'START BizBlox Generated Code : Do not remove or alter this comment
'Last Updated : Tuesday, 24 August 2004 4:01:21 PM
'BizBlox Version : 0.9.1.22818
#Region "BizBlox Generated Code"

    Sub New()
        MyBase.New(New DOFactory(New Student))
    End Sub

    'to typecast your item() property
    Default Public Shadows ReadOnly Property Item(ByVal i As Integer) As Student
        Get
            Return CType(MyBase.Item(i), Student)
        End Get
    End Property

#End Region
'END BizBlox Generated Code : Do not remove or alter this comment


    ''' -----------------------------------------------------------------------------
    ''' <summary>
    ''' Example pattern for usage of standard SQLBuilder API calls.
    ''' </summary>
    ''' <param name="name"></param>
    ''' <remarks>
    ''' </remarks>
    ''' <history>
    ''' 	[cinj]	28/07/2004	Created
    ''' </history>
    ''' -----------------------------------------------------------------------------
    Public Sub FindByStudentName(ByVal name As String)
        Dim mySql As SQLBuilder = MyBase.GetSqlBuilder()
        mySql.addWhere(Student.Columns.Name, name)
        MyBase.find(mySql)
    End Sub

    ''' -----------------------------------------------------------------------------
    ''' <summary>
    ''' Example use of the SearchBuilder in a finder method.
    ''' </summary>
    ''' <param name="SearchTerm"></param>
    ''' <remarks>
    ''' </remarks>
    ''' <history>
    ''' 	[cinj]	28/07/2004	Created
    ''' </history>
    ''' -----------------------------------------------------------------------------
    Public Sub SearchByStudentName(ByVal SearchTerm As String)
        Dim mySql As SQLBuilder = MyBase.GetSqlBuilder()
        Dim sb As New SearchBuilder(SearchTerm)
        mySql.addSearch(Student.Columns.Name, sb)
        MyBase.find(mySql)
    End Sub



End Class




